package ar.com.digitalbricks.view.imprenta.helper;

import java.util.Collection;
import java.util.EnumSet;
import java.util.HashSet;

import ar.com.digitalbricks.imprenta.general.enums.Dia;
import ar.com.digitalbricks.imprenta.persona.enums.Horario;
import ar.com.digitalbricks.view.imprenta.general.EnumView;

public class CalendarioAtencionItemView {
	private String dia;
	private HoraView ocho;
	private HoraView ocho_30;
	private HoraView nueve;
	private HoraView nueve_30;
	private HoraView diez;
	private HoraView diez_30;
	private HoraView once;
	private HoraView once_30;
	private HoraView doce;
	private HoraView doce_30;
	private HoraView trece;
	private HoraView trece_30;
	private HoraView catorce;
	private HoraView catorce_30;
	private HoraView quince;
	private HoraView quince_30;
	private HoraView dieciseis;
	private HoraView dieciseis_30;
	private HoraView diecisiete;
	private HoraView diecisiete_30;
	private HoraView dieciocho;
	private HoraView dieciocho_30;
	
	@SuppressWarnings("unchecked")
	public static Collection<CalendarioAtencionItemView> newSemanaSinAtencion(){
		Collection<CalendarioAtencionItemView> sinAtencion = new HashSet<CalendarioAtencionItemView>();
		for (Enum aEnum : EnumSet.allOf(Dia.class)){
			CalendarioAtencionItemView calendario = new CalendarioAtencionItemView();
			EnumView evDia = new EnumView(aEnum);
			calendario.dia = evDia.getDescription();
			calendario.setDiaSinAtencion();
			sinAtencion.add(calendario);
		}
		return sinAtencion;
	}

	@SuppressWarnings("unchecked")
	public static Collection<CalendarioAtencionItemView> newSemanaAtencionEstandar(){
		Collection<CalendarioAtencionItemView> sinAtencion = new HashSet<CalendarioAtencionItemView>();
		for (Enum aEnum : EnumSet.allOf(Dia.class)){
			CalendarioAtencionItemView calendario = new CalendarioAtencionItemView();
			EnumView evDia = new EnumView(aEnum);
			calendario.dia = evDia.getDescription();
			if (aEnum.equals(Dia.DOMINGO) || aEnum.equals(Dia.SABADO)){
				calendario.setDiaEstandar();
			}else{
				calendario.setDiaEstandar();
			}
			sinAtencion.add(calendario);
		}
		return sinAtencion;
	}

	public void setDiaEstandar() {
		this.ocho = new HoraView(Horario.OCHO);
		this.ocho.setAtiende(false);
		this.ocho_30 = new HoraView(Horario.OCHO_30);
		this.ocho_30.setAtiende(false);
		this.nueve = new HoraView(Horario.NUEVE);
		this.nueve.setAtiende(true);
		this.nueve_30 = new HoraView(Horario.NUEVE_30);
		this.nueve_30.setAtiende(true);
		this.diez = new HoraView(Horario.DIEZ);
		this.diez.setAtiende(true);
		this.diez_30 = new HoraView(Horario.DIEZ_30);
		this.diez_30.setAtiende(true);
		this.once = new HoraView(Horario.ONCE);
		this.once.setAtiende(true);
		this.once_30 = new HoraView(Horario.ONCE_30);
		this.once_30.setAtiende(true);
		this.doce = new HoraView(Horario.DOCE);
		this.doce.setAtiende(true);
		this.doce_30 = new HoraView(Horario.DOCE_30);
		this.doce_30.setAtiende(true);
		this.trece = new HoraView(Horario.TRECE);
		this.trece.setAtiende(true);
		this.trece_30 = new HoraView(Horario.TRECE_30);
		this.trece_30.setAtiende(true);
		this.catorce = new HoraView(Horario.CATORCE);
		this.catorce.setAtiende(true);
		this.catorce_30 = new HoraView(Horario.CATORCE_30);
		this.catorce_30.setAtiende(true);
		this.quince = new HoraView(Horario.QUINCE);
		this.quince.setAtiende(true);
		this.quince_30 = new HoraView(Horario.QUINCE_30);
		this.quince_30.setAtiende(true);
		this.dieciseis = new HoraView(Horario.DIECISEIS);
		this.dieciseis.setAtiende(true);
		this.dieciseis_30 = new HoraView(Horario.DIECISEIS_30);
		this.dieciseis_30.setAtiende(true);
		this.diecisiete = new HoraView(Horario.DIECISIETE);
		this.diecisiete.setAtiende(true);
		this.diecisiete_30 = new HoraView(Horario.DIECISIETE_30);
		this.diecisiete_30.setAtiende(true);
		this.dieciocho = new HoraView(Horario.DIECIOCHO);
		this.dieciocho.setAtiende(false);
		this.dieciocho_30 = new HoraView(Horario.DIECIOCHO_30);
		this.dieciocho_30.setAtiende(false);
	}
	
	public void setDiaSinAtencion() {
		this.ocho = new HoraView(Horario.OCHO);
		this.ocho.setAtiende(false);
		this.ocho_30 = new HoraView(Horario.OCHO_30);
		this.ocho_30.setAtiende(false);
		this.nueve = new HoraView(Horario.NUEVE);
		this.nueve.setAtiende(false);
		this.nueve_30 = new HoraView(Horario.NUEVE_30);
		this.nueve_30.setAtiende(false);
		this.diez = new HoraView(Horario.DIEZ);
		this.diez.setAtiende(false);
		this.diez_30 = new HoraView(Horario.DIEZ_30);
		this.diez_30.setAtiende(false);
		this.once = new HoraView(Horario.ONCE);
		this.once.setAtiende(false);
		this.once_30 = new HoraView(Horario.ONCE_30);
		this.once_30.setAtiende(false);
		this.doce = new HoraView(Horario.DOCE);
		this.doce.setAtiende(false);
		this.doce_30 = new HoraView(Horario.DOCE_30);
		this.doce_30.setAtiende(false);
		this.trece = new HoraView(Horario.TRECE);
		this.trece.setAtiende(false);
		this.trece_30 = new HoraView(Horario.TRECE_30);
		this.trece_30.setAtiende(false);
		this.catorce = new HoraView(Horario.CATORCE);
		this.catorce.setAtiende(false);
		this.catorce_30 = new HoraView(Horario.CATORCE_30);
		this.catorce_30.setAtiende(false);
		this.quince = new HoraView(Horario.QUINCE);
		this.quince.setAtiende(false);
		this.quince_30 = new HoraView(Horario.QUINCE_30);
		this.quince_30.setAtiende(false);
		this.dieciseis = new HoraView(Horario.DIECISEIS);
		this.dieciseis.setAtiende(false);
		this.dieciseis_30 = new HoraView(Horario.DIECISEIS_30);
		this.dieciseis_30.setAtiende(false);
		this.diecisiete = new HoraView(Horario.DIECISIETE);
		this.diecisiete.setAtiende(false);
		this.diecisiete_30 = new HoraView(Horario.DIECISIETE_30);
		this.diecisiete_30.setAtiende(false);
		this.dieciocho = new HoraView(Horario.DIECIOCHO);
		this.dieciocho.setAtiende(false);
		this.dieciocho_30 = new HoraView(Horario.DIECIOCHO_30);
		this.dieciocho_30.setAtiende(false);
	}
	
	public void setDia(String dia) {
		this.dia = dia;
	}

	public String getDia() {
		return this.dia;
	}

	public HoraView getOcho() {
		return this.ocho;
	}

	public HoraView getOcho_30() {
		return this.ocho_30;
	}

	public HoraView getNueve() {
		return this.nueve;
	}

	public HoraView getNueve_30() {
		return this.nueve_30;
	}

	public HoraView getDiez() {
		return this.diez;
	}

	public HoraView getDiez_30() {
		return this.diez_30;
	}

	public HoraView getOnce() {
		return this.once;
	}

	public HoraView getOnce_30() {
		return this.once_30;
	}

	public HoraView getDoce() {
		return this.doce;
	}

	public HoraView getDoce_30() {
		return this.doce_30;
	}

	public HoraView getTrece() {
		return this.trece;
	}

	public HoraView getTrece_30() {
		return this.trece_30;
	}

	public HoraView getCatorce() {
		return this.catorce;
	}

	public HoraView getCatorce_30() {
		return this.catorce_30;
	}

	public HoraView getQuince() {
		return this.quince;
	}

	public HoraView getQuince_30() {
		return this.quince_30;
	}

	public HoraView getDieciseis() {
		return this.dieciseis;
	}

	public HoraView getDieciseis_30() {
		return this.dieciseis_30;
	}

	public HoraView getDiecisiete() {
		return this.diecisiete;
	}

	public HoraView getDiecisiete_30() {
		return this.diecisiete_30;
	}

	public HoraView getDieciocho() {
		return this.dieciocho;
	}

	public HoraView getDieciocho_30() {
		return this.dieciocho_30;
	}

	public void setOcho(HoraView ocho) {
		this.ocho = ocho;
	}

	public void setOcho_30(HoraView ocho_30) {
		this.ocho_30 = ocho_30;
	}

	public void setNueve(HoraView nueve) {
		this.nueve = nueve;
	}

	public void setNueve_30(HoraView nueve_30) {
		this.nueve_30 = nueve_30;
	}

	public void setDiez(HoraView diez) {
		this.diez = diez;
	}

	public void setDiez_30(HoraView diez_30) {
		this.diez_30 = diez_30;
	}

	public void setOnce(HoraView once) {
		this.once = once;
	}

	public void setOnce_30(HoraView once_30) {
		this.once_30 = once_30;
	}

	public void setDoce(HoraView doce) {
		this.doce = doce;
	}

	public void setDoce_30(HoraView doce_30) {
		this.doce_30 = doce_30;
	}

	public void setTrece(HoraView trece) {
		this.trece = trece;
	}

	public void setTrece_30(HoraView trece_30) {
		this.trece_30 = trece_30;
	}

	public void setCatorce(HoraView catorce) {
		this.catorce = catorce;
	}

	public void setCatorce_30(HoraView catorce_30) {
		this.catorce_30 = catorce_30;
	}

	public void setQuince(HoraView quince) {
		this.quince = quince;
	}

	public void setQuince_30(HoraView quince_30) {
		this.quince_30 = quince_30;
	}

	public void setDieciseis(HoraView dieciseis) {
		this.dieciseis = dieciseis;
	}

	public void setDieciseis_30(HoraView dieciseis_30) {
		this.dieciseis_30 = dieciseis_30;
	}

	public void setDiecisiete(HoraView diecisiete) {
		this.diecisiete = diecisiete;
	}

	public void setDiecisiete_30(HoraView diecisiete_30) {
		this.diecisiete_30 = diecisiete_30;
	}

	public void setDieciocho(HoraView dieciocho) {
		this.dieciocho = dieciocho;
	}

	public void setDieciocho_30(HoraView dieciocho_30) {
		this.dieciocho_30 = dieciocho_30;
	}
}